home *** CD-ROM | disk | FTP | other *** search
/ Danny Amor's Online Library / Danny Amor's Online Library - Volume 1.iso / html / faqs / faq / inn-faq / part1 < prev    next >
Encoding:
Text File  |  1995-07-25  |  36.1 KB  |  954 lines

  1. Subject: INN FAQ Part 1/4: General Information
  2. Newsgroups: news.software.nntp,news.software.b,news.answers
  3. From: tal@Warren.MENTORG.COM (Tom Limoncelli)
  4. Date: 20 Aug 1994 04:00:16 -0000
  5.  
  6. Posted-By: auto-faq 2.4
  7. Archive-name: inn-faq/part1
  8.  
  9. Last Changed: $Id: FAQ-inn.1,v 1.83 1994/07/25 14:42:35 tal Exp $
  10.  
  11.                   Part 1 of 4
  12.  
  13. INN FAQ Part 1/4: General Information:
  14.                      Questions from people that don't (yet) run INN
  15.                      Specific notes for specific operating systems
  16. INN FAQ Part 2/4: Debugging Guide & Tutorial:
  17. INN FAQ Part 3/4: Operational and Misc. Questions
  18. INN FAQ Part 4/4: Appendix A: Norman's install guide
  19.  
  20.  
  21. ------------------------------
  22.  
  23. Subject:  Table Of Contents for Part 1/4
  24.  
  25. =====================================================================
  26.         TABLE OF CONTENTS FOR PART 1/4:  General Information
  27. =====================================================================
  28.  
  29. QUESTIONS FROM PEOPLE THAT DON'T (YET) RUN INN:
  30.     Where can I get the INN software?
  31.     Where can I get the latest copy of this FAQ?
  32.     What is INN?
  33.     What machines does it run on?
  34.     INN must be really complicated since this FAQ is so long!
  35.     Can I run C News with INN?
  36.     Can I run NNTP with INN?
  37.     Can I run the reference implementation (NNTP1.5) with INN?
  38.     Can I run INN on my UUCP-only machine?
  39.     Suppose I have a 286 machine?
  40.     Does INN implement NOV, xthread (trn) or xuser/xmotd (tin) commands?
  41.     Is an ident or authorization protocol supported?
  42.     Does INN do UUCP batching like C News?
  43.     Help!  How do I configure this beast?
  44.     How do I thank the FAQ maintainer?
  45.  
  46. SPECIFIC NOTES FOR SPECIFIC OPERATING SYSTEMS:
  47.     BASH tips
  48.     AIX tips
  49.     SunOS 4.1.2 tips
  50.     Ultrix tips
  51.     HP-UX tips
  52.     Linux tips
  53.     A/UX 3.0 (Macintosh) tips
  54.     Alpha OSF tips
  55.     Pyramid and system's where only root can have "cron" jobs.
  56.     All System V based Unixes (SVR4, Solaris 2.x, SCO ODT 3.0, A/UX, DELL, ...)
  57.     Solaris 2.x special needs
  58.     3Com Router users
  59.     NOV problems on a Pyramid
  60.     Warnings to people that must set HAVE_UNIX_DOMAIN to DONT
  61.  
  62.  
  63. The FAQ was written by Rich $alz <rsalz@rodan.uu.net> and is now
  64. maintained by Tom Limoncelli <tal@warren.mentorg.com>.
  65.  
  66. These documents would not exist if it weren't for the people that have
  67. submitted questions and (most importantly) answers.  THANK YOU ALL!
  68.  
  69.  
  70. =====================================================================
  71.            QUESTIONS FROM PEOPLE THAT DON'T (YET) RUN INN
  72. =====================================================================
  73.  
  74.  
  75. ------------------------------
  76.  
  77. Subject:  Where can I get the INN software?
  78.  
  79. The official archive site is ftp.uu.net in the directory
  80. networking/news/nntp/inn.  Archie current lists over 30 archive sites;
  81. three other international sites are grasp.insa-lyon.fr in
  82. pub/unix/news/inn, munnari.oz.au in pub/news/inn, and src.doc.ic.ac.uk
  83. in computing/usenet/software/transport
  84.  
  85. The latest version of INN is 1.4sec.  This is rev. 1.4 with a slight
  86. modification of certain shell scripts to fix a security hole.  Do
  87. not run 1.4 without the patch (see part 3/4 of this FAQ).
  88.  
  89.  
  90. ------------------------------
  91.  
  92. Subject:  Where can I get the latest copy of this FAQ?
  93.  
  94. 1.  This four-part FAQ is available via FTP at any FTP site that carries
  95. INN itself.
  96.  
  97. 2.  This FAQ is also posted to news.software.nntp, news.software.b and
  98.     news.answers on the 5th and 20th of every month.
  99.  
  100. 3.  You can also get this FAQ by sending email to
  101. majordomo@warren.mentorg.com with "get file faq-inn-1" on the first
  102. line of the message.  (the Subject: of the message will be ignored.)
  103. (Substitute faq-inn-2, faq-inn-3 or faq-inn-4 to get those parts).
  104.  
  105. For example:
  106.  
  107. % echo get file faq-inn-1 | mail majordomo@warren.mentorg.com
  108. % echo get file faq-inn-2 | mail majordomo@warren.mentorg.com
  109. % echo get file faq-inn-3 | mail majordomo@warren.mentorg.com
  110. % echo get file faq-inn-4 | mail majordomo@warren.mentorg.com
  111.  
  112. or
  113.  
  114. % mail majordomo@warren.mentorg.com
  115. Subject: ignored
  116. get file faq-inn-1
  117. get file faq-inn-2
  118. get file faq-inn-3
  119. get file faq-inn-4
  120. ^D
  121.  
  122. or if you csh and are a total nerd, you can:
  123.     echo 'get file new-inn.'{1,2,3,4}@ \
  124.         | tr @ '\012' | mail majordomo@warren.mentorg.com
  125.  
  126. ...or get a real hobby.
  127.  
  128.  
  129. ------------------------------
  130.  
  131. Subject:  What is INN?
  132.  
  133. For a complete answer, why not read the Usenix paper that introduced
  134. INN to the world?  It's available as
  135. ftp.uu.net:networking/news/nntp/inn/inn.usenix.ps.Z
  136.  
  137. InterNetNews is a complete Usenet system.  The cornerstone of the package
  138. is innd, an NNTP server that multiplexes all I/O.  Think of it as an nntpd
  139. merged with the B News inews, or as a C News relaynews that reads multiple
  140. NNTP streams.  Newsreading is handled by a separate server, nnrpd, that is
  141. spawned for each client.  Both innd and nnrpd have some slight variances
  142. from the NNTP protocol (although in normal use you will never notice); see
  143. the manpages.  INN separates hosts that feed you news from those that have
  144. users reading news.  If you need to support a mixed environment you will have
  145. to do some extra work; the installation manual gives some hints.
  146.  
  147.  
  148. ------------------------------
  149.  
  150. Subject:  What machines does it run on?
  151.  
  152. If you have socket() and select() then INN will probably run on your
  153. machine.  In addition to the common platforms found around the Internet
  154. (SunOS and Ultrix, for example), INN runs on IBM`s AIX, Apple's A/UX,
  155. NeXT, Solaris 2.x, most SVR4 platforms, BSDI, most free BSD systems 
  156. (NetBSD, FreeBSD, ...) and a host of others.  It might require a
  157. little bit of tweaking of some free BSD platforms that have really bad
  158. shells.
  159.  
  160.  
  161. ------------------------------
  162.  
  163. Subject:  INN must be really complicated since this FAQ is so long!
  164.  
  165. No, it's just that the FAQ is very complete.  Part 2 is so long because
  166. it includes a tutorial that tries to turn a beginner into an TCP/IP
  167. protocol expert.  Part 3 is long because the FAQ maintainer is
  168. constantly trying to add every question ever asked on
  169. news.software.nntp.  Maybe someone should volunteer to maintain an
  170. index.
  171.  
  172. A lot of the material could be integrated into the Install.ms doc.
  173.  
  174. Please post questions to news.software.nntp.  Do not send
  175. email to Tom Limoncelli directly.  By posting your question,
  176. a group of 10 or so people will be trying to help you.
  177.  
  178.  
  179. ------------------------------
  180.  
  181. Subject:  Can I run C News with INN?
  182.  
  183. No.  INN handles all article reception, filing, forwarding, and
  184. expiration.  You will get a corrupted database if you try to
  185. run INN with any other news system.  For testing, you can probably shut
  186. down your old system, bring up INN, and then reverse the process.  (INN
  187. uses the C News history file and DBZ database, so if you don't run C News
  188. you will have to do some fiddling around with those files.)
  189.  
  190.  
  191. ------------------------------
  192.  
  193. Subject:  Can I run NNTP with INN?
  194.  
  195. There's a confusion here.  NNTP is a protocol, defined in RFC 977.  There
  196. is also an implementation of the protocol, NNTP1.5, that many people call
  197. NNTP.  When there was only one implementation of the protocol, that was
  198. okay, but now that there are other implementations (for example, INN) it
  199. is getting confusing.  It would be as if "sendmail" were named "smtp."
  200. Please try to be clear -- do you mean the NNTP protocol, or the NNTP
  201. reference implementation currently maintained by Stan Barber?
  202.  
  203.  
  204. ------------------------------
  205.  
  206. Subject:  Can I run the reference implementation (NNTP1.5) with INN?
  207.  
  208. The quick answer is no.  INN listens on the NNTP port and handles all
  209. incoming traffic.  It receives articles, files them, and arranges for
  210. them to be forwarded to your peers.  If a site connects that is not
  211. listed as a peer (e.g., a local workstation that does newsreading) then
  212. the INN server hands the connection off to another program that handles
  213. just the NNTP commands that newsreaders use.  By default, this is nnrpd
  214. (notice the "r"), which implements the NNTP protocol for newsreaders
  215. (for example, it includes the POST command but not the IHAVE command).
  216. You can run the reference implementation server instead of nnrpd if you
  217. want.  Doing this can be useful if you have clients that want to do
  218. both reading and article transfer.
  219.  
  220.  
  221. ------------------------------
  222.  
  223. Subject:  Can I run INN on my UUCP-only machine?
  224.  
  225. Sure.  While not designed for this, several people are running INN on
  226. machines that do not have IP-connectivity (such as UUCP-only hosts) and
  227. are quite happy with it.  You might want to give it a try, especially if
  228. you think you will be joining the Internet some day.
  229.  
  230.  
  231. ------------------------------
  232.  
  233. Subject:  Suppose I have a 286 machine?
  234.  
  235. Won't work.  INN is designed to be a memory hog; a server that has been up
  236. for a few days while will have a working set size of a few to several
  237. megabytes, although not all of it will be resident.  For example, the
  238. server keeps the active file and list of who gets what in memory, as well
  239. as all articles that it is receiving.  Unless you can do things like
  240. "malloc(64 * 1024)" without pain, INN won't work on your machine.
  241.  
  242.  
  243. ------------------------------
  244.  
  245. Subject:  Does INN implement NOV, xthread (trn) or xuser/xmotd (tin) commands?
  246.  
  247. Newsreaders all need some way to quickly grab data from
  248. a range of articles.  trn, tin, nn, and others each developed
  249. their own database format, and their own extensions to the NNTP
  250. protocol for clients to read the database.  Then, Geoff Collyer
  251. invented NOV, the database to end all other databases.
  252.  
  253. Rather than support a different database format for each newsreader,
  254. INN supports Geoff Collyer's news overview database, NOV.  INN includes
  255. everything you need to create/maintain/expire NOV's .overview files.
  256. You only need Geoff's distribution (available via FTP on world.std.com
  257. src/news/nov.dist.tar.Z) if you want to see how he implements things,
  258. or to get his client library (useful when building some newsreaders).
  259.  
  260. It is very easy to configure INN to use NOV.  Read Part 3/4 of
  261. this faq: Subject: Cookbook example setting up NOV ("overchan")
  262. NB: The NOV code in INN 1.3 is buggy.  Use 1.4 or higher.
  263.  
  264. The xover command is used for querying the NOV database.  The xover
  265. command is very smart in that if the article has been canceled, the
  266. data isn't given out.  If the article is so new that it's data isn't in
  267. the NOV database, nnrpd opens the article and digs out the data.  xhrd
  268. and xpat make every effort to use NOV data before they dig the data out
  269. of the actual articles, thus making them considerably faster than other
  270. implementations.  The "xoverview" command does not exist.  If your
  271. server supports this command you need to upgrade.
  272.  
  273. What about TRN's xthread command?
  274.  
  275. The xthread command has code but it is not supported; look at
  276. $inn/nnrpd/nnrpd.h.  This code will probably vanish after 1.4.
  277.  
  278. What about TIN's many commands?
  279.  
  280. Tin commands are not supported.  However, other people have
  281. added TIN support.  See the next section.
  282.  
  283.  
  284.  
  285. ------------------------------
  286.  
  287. Subject:  Is an ident or authorization protocol supported?
  288.  
  289. An unsupported patch for nnrpd to add ident support can be found via
  290. FTP at ftp.csie.nctu.edu.tw:/pub/news/nnrpd-identd-patch.shar.gz.  It
  291. includes patches to add tin's xuser and xmotd commands as well as a
  292. list subscription system. (skhuang@csie.nctu.edu.tw)
  293.  
  294. Remember: ident information is only as valid as the server you connect
  295. to.  Any fool with root access (or anyone with a PC or Mac) can create
  296. a bogus ident server that will give out whatever information they want
  297. you to see.  It's not an authorization or identification protocol, it's
  298. just informational.
  299.  
  300. The authd protocol is added to nnrpd by <nhiro@isci.kyutech.ac.jp>.
  301. This unsupported patch can be found in
  302. ftp.geophys.hokudai.ac.jp:/pub/network/news/inn/patches/authd-patch-1.3.tar.gz
  303. The documentation is in Japanese.  Good luck.
  304.  
  305. In a future release, you will be able to log all POST commands with
  306. ident information if you so choose.  (Maybe INN 1.5)
  307.  
  308.  
  309. ------------------------------
  310.  
  311. Subject:  Does INN do UUCP batching like C News?
  312.  
  313. Not as part of the standard distribution.  The batching system right
  314. now is better than B News, but Rich has said he will be working on
  315. improving that part of INN in a future release.  Christophe Wolfhugel
  316. <Christophe.Wolfhugel@grasp.insa-lyon.fr> has written a package that is
  317. very much like the C News batching system, however.  You can find it on
  318. grasp.insa-lyon.fr in the pub/unix/news/inn/contrib directory.
  319.  
  320. Version 3 of Christophe's package includes a shell version and a Perl
  321. version.  Version 4, not yet planned will only be in Perl.  The
  322. configuration file has evolved from older releases in order to support
  323. new features like "minimum batching".
  324.  
  325.  
  326. ------------------------------
  327.  
  328. Subject:  Help!  How do I configure this beast?
  329.  
  330. READ AND FOLLOW THE "Install.ms" FILE.  This FAQ is meant to add to
  331. what Install.ms says not replace it.
  332.  
  333. Many people that thought the Install.ms doc was incomplete later
  334. re-read the "First Time Installation" portion and were amazed how much
  335. they missed (or just plain skipped) the first time.
  336.  
  337. You should also purchase the O'Reilly And Associates book on Managing
  338. Usenet to give yourself a good grounding on how to run a site.
  339.  
  340.  
  341. ------------------------------
  342.  
  343. Subject:  How do I thank the FAQ maintainer?
  344.  
  345. If you find this document useful, please consider making a donation to
  346. the maintainer's favorite charity:
  347.  
  348.     The Personal Liberty Fund
  349.     PO Box 11335
  350.     New Brunswick, NJ 08906-1335
  351.     USA
  352.  
  353. The PLF is a legal and educational organization which helps people in
  354. New Jersey, USA.  They have many on-going projects which range from
  355. combating youth suicide to legal advocacy.  Their Anti-Violence Project
  356. runs a phone hotline for reporting gay-bashing which helps hundreds of
  357. people a year.  The PLF is an all-volunteer organization and couldn't
  358. survive without donations.  The PLF is recognized by the IRS as a
  359. 501(c)3 tax-exempt charity.  Donations are tax deductible to the
  360. fullest extent of the law (U.S. citizens only).  Please write "INN" in
  361. the memo field of the check.
  362.  
  363.  
  364. ======================================================================
  365.             SPECIFIC NOTES FOR SPECIFIC OPERATING SYSTEMS
  366. ======================================================================
  367.  
  368. ------------------------------
  369.  
  370. Subject: BASH tips
  371.  
  372. If you are using a Unix who's /bin/sh is a hardlink to
  373. bash, you'll find problems using nntpsend.  nntpsend uses
  374. a variable named PPID, which is a read-only variable in BASH.
  375.  
  376. You'll get errors that look like this:
  377. sh: PPID: read-only variable
  378.  
  379. You can fix it using the the following patch:
  380.  
  381.  
  382. *** nntpsend~   Thu Aug 12 03:36:16 1993
  383. --- nntpsend    Sat Oct 23 15:54:11 1993
  384. ***************
  385. *** 1,4 ****
  386. ! #! /bin/sh
  387.   ##  $Revision: 1.83 $
  388.   ##  Send news via NNTP by running several innxmit processes in the background.
  389.   ##  Usage:
  390. --- 1,4 ----
  391. ! #!/usr/local/bin/bash
  392.   ##  $Revision: 1.83 $
  393.   ##  Send news via NNTP by running several innxmit processes in the background.
  394.   ##  Usage:
  395. ***************
  396. *** 130,140 ****
  397.       chmod 0660 ${LOG}
  398.       exec >>${LOG} 2>&1
  399.   fi
  400. ! PPID=$$
  401. ! echo "${PROGNAME}: [${PPID}] start"
  402.   
  403.   ##  Set up environment.
  404. ! export BATCH PROGNAME PPID INNFLAGS
  405.   
  406.   ##  Loop over all sites.
  407.   cat ${INPUT} | while read SITE HOST MAXSIZE FLAGS; do
  408. --- 130,140 ----
  409.       chmod 0660 ${LOG}
  410.       exec >>${LOG} 2>&1
  411.   fi
  412. ! CPID=$$
  413. ! echo "${PROGNAME}: [${CPID}] start"
  414.   
  415.   ##  Set up environment.
  416. ! export BATCH PROGNAME CPID INNFLAGS
  417.   
  418.   ##  Loop over all sites.
  419.   cat ${INPUT} | while read SITE HOST MAXSIZE FLAGS; do
  420. ***************
  421. *** 240,246 ****
  422.       fi
  423.   
  424.       ##  Start sending this site in the background.
  425. !     export SITE HOST LOCKS BATCHFILE PROGNAME PPID SIZE TMPDIR
  426.       sh -c '
  427.         BATCHFILE=${HOST}.nntp
  428.         LOCK=${LOCKS}/LOCK.${HOST}
  429. --- 240,246 ----
  430.       fi
  431.   
  432.       ##  Start sending this site in the background.
  433. !     export SITE HOST LOCKS BATCHFILE PROGNAME CPID SIZE TMPDIR
  434.       sh -c '
  435.         BATCHFILE=${HOST}.nntp
  436.         LOCK=${LOCKS}/LOCK.${HOST}
  437. ***************
  438. *** 247,253 ****
  439.         trap "rm -f ${LOCK} ; exit 1" 1 2 3 15
  440.         shlock -p $$ -f ${LOCK} || {
  441.             WHY="`cat ${LOCK}`"
  442. !           echo "${PROGNAME}: [${PPID}:$$] ${HOST} locked ${WHY} `date`"
  443.             exit
  444.         }
  445.         if [ -f ${SITE}.work ] ; then
  446. --- 247,253 ----
  447.         trap "rm -f ${LOCK} ; exit 1" 1 2 3 15
  448.         shlock -p $$ -f ${LOCK} || {
  449.             WHY="`cat ${LOCK}`"
  450. !           echo "${PROGNAME}: [${CPID}:$$] ${HOST} locked ${WHY} `date`"
  451.             exit
  452.         }
  453.         if [ -f ${SITE}.work ] ; then
  454. ***************
  455. *** 254,259 ****
  456. --- 254,260 ----
  457.             cat ${SITE}.work >>${BATCHFILE}
  458.             rm -f ${SITE}.work
  459.         fi
  460. +       if [ -s ${SITE} ] ; then
  461.         mv ${SITE} ${SITE}.work
  462.         if ctlinnd -s -t30 flush ${SITE} ; then
  463.             cat ${SITE}.work >>${BATCHFILE}
  464. ***************
  465. *** 260,273 ****
  466.             rm -f ${SITE}.work
  467.             test -n "${SIZE}" && shrinkfile -s${SIZE} -v ${BATCHFILE}
  468.             if [ -s ${BATCHFILE} ] ; then
  469. !               echo "${PROGNAME}: [${PPID}:$$] begin ${HOST} `date`"
  470. !               echo "${PROGNAME}: [${PPID}:$$] innxmit ${INNFLAGS} ${HOST} ..."
  471.                 eval innxmit ${INNFLAGS} ${HOST} ${BATCH}/${BATCHFILE}
  472. !               echo "${PROGNAME}: [${PPID}:$$] end ${HOST} `date`"
  473.             else
  474.                 rm -f ${BATCHFILE}
  475.             fi
  476.         fi
  477.         rm -f ${LOCK}
  478.       ' &
  479.       sleep 5
  480. --- 261,275 ----
  481.             rm -f ${SITE}.work
  482.             test -n "${SIZE}" && shrinkfile -s${SIZE} -v ${BATCHFILE}
  483.             if [ -s ${BATCHFILE} ] ; then
  484. !               echo "${PROGNAME}: [${CPID}:$$] begin ${HOST} `date`"
  485. !               echo "${PROGNAME}: [${CPID}:$$] innxmit ${INNFLAGS} ${HOST} ..."
  486.                 eval innxmit ${INNFLAGS} ${HOST} ${BATCH}/${BATCHFILE}
  487. !               echo "${PROGNAME}: [${CPID}:$$] end ${HOST} `date`"
  488.             else
  489.                 rm -f ${BATCHFILE}
  490.             fi
  491.         fi
  492. +       fi
  493.         rm -f ${LOCK}
  494.       ' &
  495.       sleep 5
  496. ***************
  497. *** 275,278 ****
  498.   
  499.   wait
  500.   rm -f ${INPUT}
  501. ! echo "${PROGNAME}: [${PPID}] stop"
  502. --- 277,280 ----
  503.   
  504.   wait
  505.   rm -f ${INPUT}
  506. ! echo "${PROGNAME}: [${CPID}] stop"
  507.  
  508.  
  509. ------------------------------
  510.  
  511. Subject:  AIX tips
  512.  
  513. Q: When I run news.daily, there's always a few lines of error
  514. messages at the end of the output:
  515.  
  516.     compress: bad file number
  517.  
  518. A:  AIX /usr/bin/compress has a bug when compressing files with zero
  519. length. Then it spits out this error.  Solution: Ignore it or use a
  520. different compress programm and change config.data accordingly.
  521. (from Kurt Jaeger <pi@rus.uni-stuttgart.de>)
  522.  
  523. Q:  innwatch doesn't work well from /etc/inittab, does it?
  524.  
  525. A:  Nope.  Instead, you can create a "subsystem" with this command:
  526.  
  527. mkssys -s innwatch -p /usr/local/news/bin/innwatch -u `id -u news` -G news -S -n 15 -f 9
  528.  
  529. Note that your path to innwatch may differ, depending on where you
  530. decided to install the inn components.  You also need to enter the
  531. command as one long line.
  532.  
  533. This will create a subsystem named "innwatch" belonging to an SRC group
  534. named "news".  The "-S" means that it uses signals for SRC to tell it
  535. when to stop and the "-n" is the SIGTERM signal, for normal shutdown,
  536. and the "-f" is the SIGKILL signal, which is sent if the process does
  537. not stop within 20 seconds.  Then, modify rc.news to issue the command
  538.  
  539.     startsrc -s innwatch
  540.  
  541. to get innwatch going.  That's it!
  542.  
  543. Shane Castle <swcxt@boco.co.gov, swcxt@csn.org>
  544.  
  545. Q:  What can I change in innwatch.ctl to make it work right?
  546.  
  547. A:  "df" has output that is a little different than other systems.
  548. Basicly, you want to 'print $3' (not 'print $4') when doing a "df" and
  549. "df -i" lines should 'print $7' (not 'print $3').
  550.  
  551. Here are diffs:
  552.  
  553. *** innwatch.ctl        Wed Apr 20 23:17:58 1994
  554. --- innwatch.ctl.aix    Mon Jul 11 14:28:34 1994
  555. ***************
  556. *** 28,40 ****
  557.   !load!+! uptime | tr -d ,. | awk '{ print $(NF - 2) }' ! gt ! 1500 ! pause ! loadav
  558.   
  559.   ##  If load is OK, check space (and inodes) on various filesystems
  560. ! ##  =()<!!! df . | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_SPOOLSPACE>@ ! throttle ! No space (spool)>()=
  561. ! !!! df . | awk 'NR == 2 { print $4 }' ! lt ! 8000 ! throttle ! No space (spool)
  562.   ##  =()<!!! df /nb/news2 | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_SPOOLSPACE>@ ! throttle ! No space (news.spool2)>()=
  563.   !!! df /nb/news2 | awk 'NR == 2 { print $4 }' ! lt ! 8000 ! throttle ! No space (news.spool2)
  564. ! ##  =()<!!! df @<_PATH_BATCHDIR>@ | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_BATCHSPACE>@ ! throttle ! No space (newsq)>()=
  565. ! !!! df /var/spool/news/out.going | awk 'NR == 2 { print $4 }' ! lt ! 800 ! throttle ! No space (newsq)
  566. ! ##  =()<!!! df @<_PATH_NEWSLIB>@ | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_LIBSPACE>@ ! throttle ! No space (newslib)>()=
  567. ! !!! df /usr/lib/news | awk 'NR == 2 { print $4 }' ! lt ! 20000 ! throttle ! No space (newslib)
  568. ! ##  =()<!!! df -i . | awk 'NR == 2 { print $3 }' ! lt ! @<INNWATCH_SPOOLNODES>@ ! throttle ! No space (spool inodes)>()=
  569. ! !!! df -i . | awk 'NR == 2 { print $3 }' ! lt ! 200 ! throttle ! No space (spool inodes)
  570. --- 28,40 ----
  571.   !load!+! uptime | tr -d ,. | awk '{ print $(NF - 2) }' ! gt ! 1500 ! pause ! loadav
  572.   
  573.   ##  If load is OK, check space (and inodes) on various filesystems
  574. ! ##  =()<!!! df . | awk 'NR == 2 { print $3 }' ! lt ! @<INNWATCH_SPOOLSPACE>@ ! throttle ! No space (spool)>()=
  575. ! !!! df . | awk 'NR == 2 { print $3 }' ! lt ! 8000 ! throttle ! No space (spool)
  576.   ##  =()<!!! df /nb/news2 | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_SPOOLSPACE>@ ! throttle ! No space (news.spool2)>()=
  577.   !!! df /nb/news2 | awk 'NR == 2 { print $4 }' ! lt ! 8000 ! throttle ! No space (news.spool2)
  578. ! ##  =()<!!! df @<_PATH_BATCHDIR>@ | awk 'NR == 2 { print $3 }' ! lt ! @<INNWATCH_BATCHSPACE>@ ! throttle ! No space (newsq)>()=
  579. ! !!! df /var/spool/news/out.going | awk 'NR == 2 { print $3 }' ! lt ! 800 ! throttle ! No space (newsq)
  580. ! ##  =()<!!! df @<_PATH_NEWSLIB>@ | awk 'NR == 2 { print $3 }' ! lt ! @<INNWATCH_LIBSPACE>@ ! throttle ! No space (newslib)>()=
  581. ! !!! df /usr/lib/news | awk 'NR == 2 { print $3 }' ! lt ! 20000 ! throttle ! No space (newslib)
  582. ! ##  =()<!!! df -i . | awk 'NR == 2 { print $7 }' ! lt ! @<INNWATCH_SPOOLNODES>@ ! throttle ! No space (spool inodes)>()=
  583. ! !!! df -i . | awk 'NR == 2 { print $7 }' ! lt ! 200 ! throttle ! No space (spool inodes)
  584.  
  585.  
  586. ------------------------------
  587.  
  588. Subject:  SunOS 4.1.2 tips
  589.  
  590. SunOS 4.1.2 (but not 4.1.1 or 4.1.3) broke the write system call but a
  591. patch is available.  Any write could fail "half way", it is just more
  592. likely to happen when writing large files and in-core DBZ writes the
  593. history file out in one chunk.  See the "Known Problems" section of the
  594. installation manual.
  595.  
  596.  
  597. ------------------------------
  598.  
  599. Subject:  Ultrix tips
  600.  
  601. Tip #1:  Ultrix has a "mmap()" function, but it doesn't do the same
  602. thing as the SunOS/BSD mmap() function.  Therefore, do not configure
  603. INN to use mmap() on a Ultrix system.  INN wants to find a mmap()
  604. function that is like the one on SunOS/BSD systems.
  605.  
  606. Tip #2:  The sendsys script breaks Ultrix 'nawk'.  You can make
  607. a 1-line change or you can switch to 'awk' or "gawk".
  608. Original line:
  609.     ${AWK} "/^$1"'[/:\\]/,/[^\\]$/' ${NEWSFEEDS} >${TEMP}
  610. Modified line:
  611.     ${AWK} "/^$1"'[\/:\\]/,/[^\\]$/' ${NEWSFEEDS} >${TEMP}
  612. The original line will work with awk, gawk, but not nawk.
  613. The modified line will work with awk, gawk, or nawk.
  614. If you have gawk running on your machine use it.  Otherwise, switch to
  615. awk.
  616.  
  617. Tip #3: The syslog on Ultrix sucks rotten eggs and Digital refuses to
  618. fix it.  (source: everyone that uses Ultrix and has ever used other
  619. systems)  Luckily, you can replace it with the routine that comes with
  620. INN.  However, some people have had better luck installing the syslog
  621. that can be found on
  622. "gatekeeper.dec.com:/pub/DEC/jtkohl-syslog-complete.tar.Z".  It still
  623. works with old clients but does new-style syslogging, too.  Works great
  624. for me so far.  (this information from:  nelson@reed.edu (Nelson
  625. Minar)).  The syslog that is shipped with INN works pretty well but
  626. there have been some claims that some old clients don't like it.
  627.  
  628.  
  629. ------------------------------
  630.  
  631. Subject:  HP-UX tips
  632.  
  633. Q.  My logs keep telling me there is no space for articles
  634. A.  Edit innwatch.ctl to use "bdf" instead of "df".
  635.  
  636. Q. I am running inn on an HP machine. INN won't start up automatically.
  637. I can start it manually.  There is no problem with news or INN once
  638. it is started.
  639.  
  640. A.  Try adding a "sleep 10" to the bottom of /etc/rc.news, or in
  641. /etc/rc, right after /etc/rc.news is invoked.  On some machines,
  642. including HP, the shell started by "#!/bin/sh" when /etc/rc is executed
  643. will exit before innd has disassociated itself from that shell.  This
  644. causes innd to exit, sometimes without printing an error message.
  645. (source: pjoslin@mbvlab.wpafb.af.mil (Paul Joslin ))
  646.  
  647. This problem goes away if you set HAVE_SETSID to "DO".  Something to do
  648. with Posix Session Leader concepts.  Ick.  (source: Steve Howie 
  649. <scotty@piranha.cs.uoguelph.ca>)
  650.  
  651. HP-UX 8.x and 9.x users might find a problem with getting innwatch to
  652. start up.  People have found that having "at" start it seems to work
  653. more reliably than other methods:
  654.  
  655. ${DOINNWATCH} && {
  656.     echo "${INNWATCH} &" | su ${NEWSUSER} -c 'at now + 2 min' > /dev/null
  657. }
  658.  
  659. The '&' in the command line prevents innwatch from taking up an at-job 
  660. slot.  SysV-style crons have a per-category and overall limit on the 
  661. number of jobs executing simultaneously.
  662.  
  663.  
  664. ------------------------------
  665.  
  666. Subject:  Linux tips
  667.  
  668. | nntpsend.log says the following.
  669.  
  670. | nntpsend: [214:222] innxmit -a -t300 -T1800
  671. | travelers.mail.cornell.edu ...
  672. | Ignoring line "cornell/test/13 805 ..."
  673. | sh: PPID read-only variable
  674.  
  675. Tomasz Surmacz <tsurmacz@ict.pwr.wroc.pl> writes:
  676.  
  677. If you are using INN under Linux or have your /bin/sh a symlink to
  678. /bin/bash the above problem appears (in nntpsend precisely speaking,
  679. not innxmit)
  680.  
  681. The problem is that bash already defines the PPID variable and
  682. nntpsend is trying to use it too.  To fix this:
  683.  
  684. 1. comment out line PPID = $$
  685. 2. change all occurences of PPID to say PARENTPID
  686.  
  687. I have also noticed that changing first line of nntpsend from
  688. '#!/bin/sh' to "!/bin/bash" helps in such occasions.
  689.  
  690.  
  691. ------------------------------
  692.  
  693. Subject:  A/UX 3.0 (Macintosh) tips
  694.  
  695. Tip #1: Use the INN malloc.
  696.  
  697. Tip #2:  If you are running INN 1.4 on a Mac running A/UX 3.0.1, Every
  698. so often, (generally when someone fires up a reader), INN goes beserk.
  699. Syslog says:
  700.  
  701.     innd: ME cant select Bad file number
  702.  
  703. This message repeats about 20 times per second.  It freezes up my
  704. computer and I need to reboot.
  705.  
  706. That's a kernel bug. You do have to reboot.
  707.  
  708. If you compiled inn with gcc, don't. My experience was that somehow, if
  709. INN was compiled with GCC the kernel bug is triggered, but that doesn't
  710. happen with cc.
  711.  
  712.  
  713. ------------------------------
  714.  
  715. Subject:  Alpha OSF tips:
  716.  
  717. To compile INN for the DEC Alpha, follow the instructions in the INN
  718. patch archive on ftp.pop.psu.edu:/pub/src/news/inn-patches
  719.  
  720. In rc.news you need to start $INNWATCH using the following:
  721.  
  722. ${DOINNWATCH} && {
  723.     echo "${INNWATCH} &" | su ${NEWSUSER} -c 'at now + 2 min' > /dev/null
  724. }
  725.  
  726. The '&' in the command line prevents innwatch from taking up an at-job
  727. slot.  SysV-style crons have a per-category and overall limit on the 
  728. number of jobs executing simultaneously.
  729.  
  730.  
  731.  
  732. ------------------------------
  733.  
  734. Subject:  Pyramid and system's where only root can have "cron" jobs.
  735.  
  736. Your cron jobs may not work if you use:
  737.  
  738.     su news -c /usr/lib/news/bin/news.daily delayrm expireover
  739.  
  740. Instead, you must put the entire command in quotes.  Like this:
  741.  
  742.     su news -c "/usr/lib/news/bin/news.daily delayrm expireover"
  743.  
  744. Look for "Pyramid" in part ??? of this FAQ for details.
  745.  
  746. ------------------------------
  747.  
  748. Subject:  System V based Unixes (SVR4, Solaris 2.x, SCO ODT 3.0, A/UX, DELL, ...)
  749.  
  750. If you are running any non-BSD (i.e. System V based) Unix you MUST have
  751. the following option set:
  752.  
  753. ##  How should close-on-exec be done?  Pick IOCTL or FCNTL.
  754. #### =()<CLX_STYLE              @<CLX_STYLE>@>()=
  755. CLX_STYLE               FCNTL
  756.  
  757. This includes SVR4, Solaris 2.x, A/UX and SCO ODT 3.0.  (SVR4 means
  758. systems based on System V Release 4 from USL.  Please check your manual
  759. to see if your operating system is based on SVR4.)
  760.  
  761. This CLX_STYLE setting is clearly stated in the Install.ms file and
  762. repeated here since so many people post to news.software.nntp after
  763. ignoring the warnings.
  764.  
  765. If CLX_STYLE isn't set to FCNTL, you'll get tons of overchan processes
  766. hanging around.
  767.  
  768. With SCO ODT 3.0 and MOST systems, innd will link and run if you use
  769. IOCTL but eventually will stop answering incoming calls.
  770.  
  771. Don't be fooled.  Just because it compiles doesn't mean it's going to
  772. work.
  773.  
  774. If you start innd on an AT&T SysV Rel 4.0 machine and get syslog
  775. messages like:
  776.     localhost:15 cant setsockopt(SNDBUF) Protocol error
  777.     localhost:15 cant setsockopt(RCVBUF) Protocol error
  778. then you should FIRST try to change HAVE_UNIX_DOMAIN to "DONT" in
  779. config.data.  If that doesn't fix the problem, you should comment out
  780. the "setsockopt()" calls and things will work.
  781.  
  782. Many SVR4 for i486 binaries (sendmail, mh, vmail, innd, rnews are now
  783. on ftp.germany.eu.net in pub/comp/i486/svr4/*.SVR4.tgz But remember
  784. that some of the above need site specific changes, so their usefulness
  785. may be limited.
  786.  
  787. If you get syslog messages that say, "ME cant accept RCreader"
  788. please refer to Part 2 of this FAQ.
  789.  
  790. DELL ships their Unix with /dev/log chmod'ed to 0644 which means nobody
  791. can syslog anything.  Pretty stupid, eh?  INN uses syslog extensively.
  792. If you find that you don't get any syslog messages check to see if you
  793. need to: "chmod 0666 /dev/log".
  794.  
  795. If your SVR4 system still doesn't run correctly, check the
  796. Solaris 2.x suggestions.
  797.  
  798.  
  799. ------------------------------
  800.  
  801. Subject:  Solaris 2.x special needs
  802.  
  803. If "inews" outputs "Bad Message-ID" when posting Under Solaris 2.x
  804. (where x = 0, 1, 2 or 3) you need to change the file "getfqdn.c".  Find
  805. the lines that read:
  806.  
  807.     if (strchr(hp->h_name, '.') == NULL) {
  808.         /* Try to force DNS lookup if NIS/whatever gets in the way. */
  809.         (void)strncpy(temp, buff, sizeof buff);
  810.         (void)strcat(temp, ".");
  811.         hp = gethostbyname(temp);
  812.     }
  813.  
  814. and delete them.
  815.  
  816. Under Solaris 2.[012] (SunOS 5.0, 5.1, 5.2) you must add the following
  817. at the beginning of each file using gethostbyname():
  818.  
  819. #define gethostbyname __switch_gethostbyname
  820.  
  821. Under Solaris 2.3 gethostbyname() might work without changes depending
  822. on your configuration.  We haven't figured out when they work and when
  823. they don't.  If you run into problems, try to change "gethostbyname()"
  824. to "solaris_gethostbyname()" and then use the gethostbyname() listed in
  825. the Solaris Porting FAQ.  This isn't a perfect solution, because you
  826. now need a different binary for Solaris 2.[012] systems.
  827.  
  828. It would be great if someone were to submit a solaris_gethostbyname()
  829. function who's binary works under all Solaris revs and gives all the
  830. semantics of BSD gethostbyname().  In particular, one that doesn't have
  831. the problems discussed in sun bugid #1126573 or #1135988.  It would be
  832. amazing if this was submitted by one of the many Sun employees that
  833. flame the INN FAQ maintainer in comp.sys.sun.admin everytime he bitches
  834. about how much he hates Solaris 2.x. :-)
  835.  
  836. Under all Solaris 2.* versions there is a problem with innwatch.ctl.
  837. It expects to use "df -i" to find out how many inodes are free on your
  838. disk.  /usr/{sbin,5bin,bin}/df doesn't support the "-i" option, it has
  839. a "-e" option that outputs the info you want, but in a different
  840. format.  You should use "/usr/ucb/df -i" instead, since this version of
  841. df includes the "-i" option.
  842.  
  843. /usr/ucb/df is part of the BSD Compatibility stuff.  If you loaded
  844. Solaris 2.x without that, you can replace innwatch.ctl's disk checks
  845. with these lines:
  846.  
  847. ##  If load is OK, check space (and inodes) on various filesystems
  848. ##  =()<!!! /usr/bin/df -k . | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_SPOOLSPACE>@ ! throttle ! No space (spool)>()=
  849. !!! /usr/bin/df -k . | awk 'NR == 2 { print $4 }' ! lt ! 8000 ! throttle ! No space (spool)
  850. ##  =()<!!! /usr/bin/df -k @<_PATH_BATCHDIR>@ | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_BATCHSPACE>@ ! throttle ! No space (newsq)>()=
  851. !!! /usr/bin/df -k /news2/spool/out.going | awk 'NR == 2 { print $4 }' ! lt ! 800 ! throttle ! No space (newsq)
  852. ##  =()<!!! /usr/bin/df -k @<_PATH_NEWSLIB>@ | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_LIBSPACE>@ ! throttle ! No space (newslib)>()=
  853. !!! /usr/bin/df -k /news2/privcontrol | awk 'NR == 2 { print $4 }' ! lt ! 40000 ! throttle ! No space (newslib)
  854. ##  =()<!!! /usr/bin/df -k @<_PATH_OVERVIEWDIR>@ | awk 'NR == 2 { print $4 }' ! lt ! @<INNWATCH_OVERVIEWSPACE>@ ! throttle ! No space (overview)>()=
  855. !!! /usr/bin/df -k /news3/overview | awk 'NR == 2 { print $4 }' ! lt ! 6000 ! throttle ! No space (overview)
  856. ##  =()<!!! /usr/bin/df -e . | awk 'NR == 2 { print $2 }' ! lt ! @<INNWATCH_SPOOLNODES>@ ! throttle ! No space (spool inodes)>()=
  857. !!! /usr/bin/df -e . | awk 'NR == 2 { print $2 }' ! lt ! 200 ! throttle ! No space (spool inodes)
  858.  
  859. Don't run the "lint" step if you use Solaris.  In fact, nobody needs to
  860. execute this step except Rich, when he's writing new code.  If you have
  861. a Solaris machine without "lint", just make "lint" a symlink to
  862. "/bin/echo".
  863.  
  864. People running Solaris 2.3 have built INN with HAVE_UNIX_DOMAIN set to
  865. TRUE and everything seems to be ok.  I guess Sun has fixed enough
  866. bugs in 2.3 to make it usable.  I recommend the latest "recommended
  867. patches" if you run any version of Solaris 2.x.
  868.  
  869.  
  870. ------------------------------
  871.  
  872. Subject:  3Com Router users
  873.  
  874. If you observe strange behavior, like nnrpd locking and not sending
  875. some articles to the clients, and if you find no clues about other
  876. potential problems, then check your IP layer: some users have observed
  877. bugs in the IP implementation of 3Com routers caused TCP
  878. sessions lock outs.  You have very probably also NFS problems then.
  879. Upgrading to the latest PROMs fixes this totally bizarre problem.
  880.  
  881.  
  882. ------------------------------
  883.  
  884. Subject:  NOV problems on a Pyramid
  885.  
  886. Q:  I just turned on the overview stuff and I don't think news.daily is
  887. properly expiring the .overview files.  I'm using a Pyramid.
  888.  
  889. A:  Do you need quotes in your crontab entry?  Look at your news.daily
  890. report -- expire using "expireover delayrm" should take a few minutes.
  891. If it takes longer than, say, 10-20 minutes, then the keywords aren't
  892. being seen by news.daily so perhaps the commandline quoting is wrong.
  893.  
  894. i.e. you had:
  895.  
  896.     su news -c /usr/lib/news/bin/news.daily delayrm expireover
  897.  
  898. You should have:
  899.  
  900.     su news -c "/usr/lib/news/bin/news.daily delayrm expireover"
  901.  
  902.  
  903. ------------------------------
  904.  
  905. Subject:  Warnings to people that must set HAVE_UNIX_DOMAIN to DONT
  906.  
  907. Disclaimer:  First of all, if you have to set HAVE_UNIX_DOMAIN to DONT,
  908. YOU HAVE TO SET IT to DONT.  It's not a choice you can make, it's a
  909. description of the operating system that you've purchased.  If you've
  910. wrongly set this variable to DO your system isn't going to work *at*
  911. *all*.
  912.  
  913. When you use POST (the NNTP command), you are talking to nnrpd.  nnrpd
  914. cleans up your headers, adds the missing headers that it is allowed to
  915. add, checks whatever it checks, and then submits the finalized version
  916. to innd.  How does it talk to innd?
  917.  
  918. If you have HAVE_UNIX_DOMAIN set to DO, nnrpd opens a Unix domain
  919. socket and sends the text.  At this point it is talking to innd
  920. somewhat like ctlinnd does.  innd can trust that the post isn't
  921. forged since it is coming from a program trustworthy enough to
  922. get to the socket (which isn't much).
  923.  
  924. If you have HAVE_UNIX_DOMAIN set to DONT, it has no choice but to open
  925. a socket to port 119, issue the "IHAVE" command, and send the text that
  926. way (just like a remote newsreader).  This means that innd (not another
  927. nnrpd) has to be at the other end of the pipe.  If it opens the
  928. connection and sees a "nnrpd" you're hosed and you get "441 480
  929. Transfer permission denied".  (Better the "441 480" message than an
  930. infinate loop of nnrpd's connecting to nnrpd's!)  To get innd to not
  931. hand off the connection to a nnrpd process, you must have the host's
  932. name in the hosts.nntp file.  (don't forget to do "ctlinnd reload
  933. hosts.nntp")
  934.  
  935. If you have your host's name in the hosts.nntp file, then any
  936. newsreader running on your nntphost must be "INN-aware" (i.e. that they
  937. issue the "mode reader" command) or they must read news via the file
  938. system instead of NNTP.
  939.  
  940. If you have NNTP-based newsreaders that can't send the "mode reader"
  941. command, you can try including "server: localhost" in your inn.conf
  942. file, but then you must have a different inn.conf file for the other
  943. machines.  If you can't do that, you have no other options but to
  944. recompile your newsreaders.
  945.  
  946. Remember, if you change your inn.conf file, you must shutdown and
  947. restart innd.  There is no "ctlinnd reload inn.conf" command.
  948. -- 
  949.     Tom Limoncelli -- tal@warren.mentorg.com (work) -- tal@plts.org (play)
  950.  
  951.                    The internet is like a box of chocolates.
  952.  
  953.  
  954.